<?php
/* @var $this ClientesController */
/* @var $model Clientes */

Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
	$('.search-form').toggle();
	return false;
});
$('.search-form form').submit(function(){
	$('#clientes-grid').yiiGridView('update', {
		data: $(this).serialize()
	});
	return false;
});
");
?>

<h1>Administrador de Clientes</h1>


<?php echo CHtml::link('Busqueda Avanzada','#',array('class'=>'search-button')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_searchCliente',array(
	'model'=>$model,
)); ?>
</div><!-- search-form -->

<?php $this->widget('zii.widgets.grid.CGridView', array(
	'id'=>'clientes-grid',
	'selectionChanged' => 'seleccion',
	'dataProvider'=>$model->filtro(),
	'filter'=>$model,
	'columns'=>array(
		'IDCL',
		'NOMBRE',
		'APELLIDO',
		/*
		'ESTADO',
		*/
	),
)); ?>


